package com.education.seckill.mq;

import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;


@Component
public class mqSender {

    @Autowired
    private RabbitTemplate rabbitTemplate;

    public void sendSeckillMes(Long id ){
        rabbitTemplate.convertAndSend("seckill_exchange","seckill.message",id);
    }
}
